import request from '@/utils/request'

// 获取机构列表数据
export function list(token,data){
  return request({
    url: 'thk/customer_organization/get_select',
    method: 'post',
    params: {token},
    data
  })
}

// 添加机构
export function add(token,data){
  return request({
    url: 'thk/customer_organization/add',
    method: 'post',
    params: {token},
    data
  })
}

// 编辑机构
export function edit(token,data){

  console.log(data)
  return request({
    url: 'thk/customer_organization/edit',
    method: 'post',
    params: {token},
    data
  })
}

// 删除机构
export function del(token,customer_organization_id) {
  return request({
    url: 'thk/customer_organization/delete',
    method: 'post',
    params: {token},
    data: {customer_organization_id}
  })
}

// 获取机构信息
export function detail(token,data){
  
  return request({
    url: 'thk/customer_organization/detail',
    method: 'post',
    params: {token},
    data
  })

}
